********************************
Compiling mdAddrRubyWrapper.cpp
********************************

You may need to recompile mdAddrRubyWrapper.cpp if you are not using a version of Ruby that is compatible with the mdAddrRubyWrapper.dll that is supplied. 

Prerequisites:
	
	Visual C++ Compiler
	Ruby (tested with 1.8.6)

To compile mdAddrRubyWrapper.cpp, a bat file has been supplied. This bat file requires the Visual Studio C++ compiler. To use the compiler, you must set up its environment by executing vcvars32.bat in the Visual Studio C++ bin folder. Read the comments at the top of BuildWrapper.bat for more details.

You must then set the path to the Ruby Include and Library path. You also need to set the path of the Address Object library (mdAddr.dll). The default locations of these files are set for 32-bit but may require changes if your system is different.
* 64bit version available in C:\Program Files\Melissa DATA\DQT\AddrObj\dll_64bit

set mdAddrPath to the directory containing mdAddr.dll
set RubyIncludePath to ruby\src\ruby-1.8.6-p111" directory. May be different for other versions of Ruby.
set RubyIncludePath2 to ruby\lib\ruby\1.8\i386-mswin32 directory
set RubyLibraryPath to ruby\lib directory

You may also need to find C:\ruby\lib\ruby\1.8\i386-mswin32\config.h and comment out the first 3 lines to compile. 

You will also need to change the Ruby dependency that the code needs based on your version of Ruby. In BuildWrapper.bat, you will need to change the following to match your installation of Ruby:

	-DEFAULTLIB:msvcrt-ruby18.lib

The msvcrt-rubyxx.lib file is found in your ruby\lib directory.


Now, you can run BuildWrapper.bat to create mdAddrRubyWrapper.dll.

****
Note
****

Q. I get a "MSC version unmatch" error. 
A. You will need to find C:\ruby\lib\ruby\1.8\i386-mswin32\config.h and comment out the first 3 lines. The first 3 lines 
may look like this after commenting them out.
	//#if _MSC_VER != 1200
	//#error MSC version unmatch
	//#endif